Dynomotion

Group: DynoMotion Message: 1319 From: morgtod Date: 6/22/2011
Subject: Re: Tool changer code - persist.UserData
Does the persist.UserData store data for the next time the c program is run? Like for knowing which tool is in the chuck the next time the toolchange calls? There is a small toolchanger.c example, but a bit more info would be helpful.

Todd




--- In DynoMotion@yahoogroups.com, "morgtod" <todmorg@...> wrote:
>
> Are there any tool changer examples? I have a 12 position rotary and a 10 position pick and place for 2 different spindles on the same machine ( 1-7000 rpm and 1-40000 rpm spindle ). I would like to be able to pick which spindle is going to be used by the tool #, like 49 and below turn on the low speed, and 50 and above turn on the high speed with an offset in the x because the high speed is a couple inces to the left.
>
> Note- The spindles are at a fixed X distance from each other.
>
> Todd
>
Group: DynoMotion Message: 1320 From: Tom Kerekes Date: 6/22/2011
Subject: Re: Tool changer code - persist.UserData
Hi Todd,
 
Yes the persist.UserData[100] variables are global and persist from one execution to the next and/or from one thread/program to the next.  So you could use that to pass info from the C program that does the Tool Change to the Spindle Program that turns on the Spindle so it knows which Spindle to turn on.  But actually the Tool Number is downloaded to the Tool Change program in a persist variable so it is probably already there.
 
Sorry we don't have more examples.  There are a lot of variation in Tool Changers.  The first step would probably be to try to do a tool change manually by toggling bits on the Digital IO Screen and/or Console Commands to see if you can find a sequence that works.  If you describe the sequence in detail I might be able to help.
 
Regards
TK
 


--- On Wed, 6/22/11, morgtod <todmorg@...> wrote:

From: morgtod <todmorg@...>
Subject: [DynoMotion] Re: Tool changer code - persist.UserData
To: DynoMotion@yahoogroups.com
Date: Wednesday, June 22, 2011, 10:17 AM

 


Does the persist.UserData store data for the next time the c program is run? Like for knowing which tool is in the chuck the next time the toolchange calls? There is a small toolchanger.c example, but a bit more info would be helpful.

Todd

--- In DynoMotion@yahoogroups.com, "morgtod" <todmorg@...> wrote:
>
> Are there any tool changer examples? I have a 12 position rotary and a 10 position pick and place for 2 different spindles on the same machine ( 1-7000 rpm and 1-40000 rpm spindle ). I would like to be able to pick which spindle is going to be used by the tool #, like 49 and below turn on the low speed, and 50 and above turn on the high speed with an offset in the x because the high speed is a couple inces to the left.
>
> Note- The spindles are at a fixed X distance from each other.
>
> Todd
>

Group: DynoMotion Message: 1330 From: morgtod Date: 6/22/2011
Subject: Re: Tool changer code - persist.UserData
Here's the rough sequence

Machine is already homed

1-move to machine cordinates z-4, then x0,y5
2-sw8 high //toolarm solenoid
3-wait for opto in 4 //toolarm in position sensor, toggle e-stop and printscreen warning if not
4-toggle sw4, wait 4 seconds //low speed drawbar, drop tool
5-check opto in 5 went low//drawbar sensor, make sure tool dropped, toggle e-stop and printscreen warning if not
6-g0z0 // move up to clear tool tray
7-turn tool tray to new tool // I have the tray setup as "A" for now, with the tools at 1" steps, ( g0a6 turns the tray to tool6 )
8-g0z-4 // drop down into pickup position
9-disable sw4 // grab the tool with low speed drawbar, the grabbing action lifts the tool off the tray far enough for the tray to swing away
10-check opto in 5 went high//make sure new tool has been grabbed, toggle e-stop and printscreen warning if not
11-sw8 low // toolarm retract
12-check opto in 3 // toolarm retracted sensor, toggle e-stop and printscreen warning if not
13- continue cutting


This would get me going with one spindle, I would start on the 2nd after this is working.

I'll post my toolchanger files in the files section of the group, one they are working.


Thanks....




--- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@...> wrote:
>
> Hi Todd,
>  
> Yes the persist.UserData[100] variables are global and persist from one execution to the next and/or from one thread/program to the next.  So you could use that to pass info from the C program that does the Tool Change to the Spindle Program that turns on the Spindle so it knows which Spindle to turn on.  But actually the Tool Number is downloaded to the Tool Change program in a persist variable so it is probably already there.
>  
> Sorry we don't have more examples.  There are a lot of variation in Tool Changers.  The first step would probably be to try to do a tool change manually by toggling bits on the Digital IO Screen and/or Console Commands to see if you can find a sequence that works.  If you describe the sequence in detail I might be able to help.
>  
> Regards
> TK
>  
>
>
> --- On Wed, 6/22/11, morgtod <todmorg@...> wrote:
>
>
> From: morgtod <todmorg@...>
> Subject: [DynoMotion] Re: Tool changer code - persist.UserData
> To: DynoMotion@yahoogroups.com
> Date: Wednesday, June 22, 2011, 10:17 AM
>
>
>  
>
>
>
>
>
> Does the persist.UserData store data for the next time the c program is run? Like for knowing which tool is in the chuck the next time the toolchange calls? There is a small toolchanger.c example, but a bit more info would be helpful.
>
> Todd
>
> --- In DynoMotion@yahoogroups.com, "morgtod" <todmorg@> wrote:
> >
> > Are there any tool changer examples? I have a 12 position rotary and a 10 position pick and place for 2 different spindles on the same machine ( 1-7000 rpm and 1-40000 rpm spindle ). I would like to be able to pick which spindle is going to be used by the tool #, like 49 and below turn on the low speed, and 50 and above turn on the high speed with an offset in the x because the high speed is a couple inces to the left.
> >
> > Note- The spindles are at a fixed X distance from each other.
> >
> > Todd
> >
>
Group: DynoMotion Message: 1334 From: morgtod Date: 6/22/2011
Subject: Re: Tool changer code - persist.UserData
one more important detail- do not allow a toolchange if the machine has not been homed!!!

--- In DynoMotion@yahoogroups.com, "morgtod" <todmorg@...> wrote:
>
> Here's the rough sequence
>
> Machine is already homed
>
> 1-move to machine cordinates z-4, then x0,y5
> 2-sw8 high //toolarm solenoid
> 3-wait for opto in 4 //toolarm in position sensor, toggle e-stop and printscreen warning if not
> 4-toggle sw4, wait 4 seconds //low speed drawbar, drop tool
> 5-check opto in 5 went low//drawbar sensor, make sure tool dropped, toggle e-stop and printscreen warning if not
> 6-g0z0 // move up to clear tool tray
> 7-turn tool tray to new tool // I have the tray setup as "A" for now, with the tools at 1" steps, ( g0a6 turns the tray to tool6 )
> 8-g0z-4 // drop down into pickup position
> 9-disable sw4 // grab the tool with low speed drawbar, the grabbing action lifts the tool off the tray far enough for the tray to swing away
> 10-check opto in 5 went high//make sure new tool has been grabbed, toggle e-stop and printscreen warning if not
> 11-sw8 low // toolarm retract
> 12-check opto in 3 // toolarm retracted sensor, toggle e-stop and printscreen warning if not
> 13- continue cutting
>
>
> This would get me going with one spindle, I would start on the 2nd after this is working.
>
> I'll post my toolchanger files in the files section of the group, one they are working.
>
>
> Thanks....
>
>
>
>
> --- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@> wrote:
> >
> > Hi Todd,
> >  
> > Yes the persist.UserData[100] variables are global and persist from one execution to the next and/or from one thread/program to the next.  So you could use that to pass info from the C program that does the Tool Change to the Spindle Program that turns on the Spindle so it knows which Spindle to turn on.  But actually the Tool Number is downloaded to the Tool Change program in a persist variable so it is probably already there.
> >  
> > Sorry we don't have more examples.  There are a lot of variation in Tool Changers.  The first step would probably be to try to do a tool change manually by toggling bits on the Digital IO Screen and/or Console Commands to see if you can find a sequence that works.  If you describe the sequence in detail I might be able to help.
> >  
> > Regards
> > TK
> >  
> >
> >
> > --- On Wed, 6/22/11, morgtod <todmorg@> wrote:
> >
> >
> > From: morgtod <todmorg@>
> > Subject: [DynoMotion] Re: Tool changer code - persist.UserData
> > To: DynoMotion@yahoogroups.com
> > Date: Wednesday, June 22, 2011, 10:17 AM
> >
> >
> >  
> >
> >
> >
> >
> >
> > Does the persist.UserData store data for the next time the c program is run? Like for knowing which tool is in the chuck the next time the toolchange calls? There is a small toolchanger.c example, but a bit more info would be helpful.
> >
> > Todd
> >
> > --- In DynoMotion@yahoogroups.com, "morgtod" <todmorg@> wrote:
> > >
> > > Are there any tool changer examples? I have a 12 position rotary and a 10 position pick and place for 2 different spindles on the same machine ( 1-7000 rpm and 1-40000 rpm spindle ). I would like to be able to pick which spindle is going to be used by the tool #, like 49 and below turn on the low speed, and 50 and above turn on the high speed with an offset in the x because the high speed is a couple inces to the left.
> > >
> > > Note- The spindles are at a fixed X distance from each other.
> > >
> > > Todd
> > >
> >
>
Group: DynoMotion Message: 1336 From: Tom Kerekes Date: 6/22/2011
Subject: Re: Tool changer code - persist.UserData
Hi Todd,
 
I've attached a rough program to hopefully get you started.
 
Just run, modify, and run it from the C Programs Screen until after it is working.  Then we can make it callable and use the passed Tool number from KMotionCNC.
 
I hope this helps.
 
TK

--- On Wed, 6/22/11, morgtod <todmorg@...> wrote:

From: morgtod <todmorg@...>
Subject: [DynoMotion] Re: Tool changer code - persist.UserData
To: DynoMotion@yahoogroups.com
Date: Wednesday, June 22, 2011, 11:17 AM

 
Here's the rough sequence

Machine is already homed

1-move to machine cordinates z-4, then x0,y5
2-sw8 high //toolarm solenoid
3-wait for opto in 4 //toolarm in position sensor, toggle e-stop and printscreen warning if not
4-toggle sw4, wait 4 seconds //low speed drawbar, drop tool
5-check opto in 5 went low//drawbar sensor, make sure tool dropped, toggle e-stop and printscreen warning if not
6-g0z0 // move up to clear tool tray
7-turn tool tray to new tool // I have the tray setup as "A" for now, with the tools at 1" steps, ( g0a6 turns the tray to tool6 )
8-g0z-4 // drop down into pickup position
9-disable sw4 // grab the tool with low speed drawbar, the grabbing action lifts the tool off the tray far enough for the tray to swing away
10-check opto in 5 went high//make sure new tool has been grabbed, toggle e-stop and printscreen warning if not
11-sw8 low // toolarm retract
12-check opto in 3 // toolarm retracted sensor, toggle e-stop and printscreen warning if not
13- continue cutting

This would get me going with one spindle, I would start on the 2nd after this is working.

I'll post my toolchanger files in the files section of the group, one they are working.

Thanks....

--- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@...> wrote:
>
> Hi Todd,
>  
> Yes the persist.UserData[100] variables are global and persist from one execution to the next and/or from one thread/program to the next.  So you could use that to pass info from the C program that does the Tool Change to the Spindle Program that turns on the Spindle so it knows which Spindle to turn on.  But actually the Tool Number is downloaded to the Tool Change program in a persist variable so it is probably already there.
>  
> Sorry we don't have more examples.  There are a lot of variation in Tool Changers.  The first step would probably be to try to do a tool change manually by toggling bits on the Digital IO Screen and/or Console Commands to see if you can find a sequence that works.  If you describe the sequence in detail I might be able to help.
>  
> Regards
> TK
>  
>
>
> --- On Wed, 6/22/11, morgtod <todmorg@...> wrote:
>
>
> From: morgtod <todmorg@...>
> Subject: [DynoMotion] Re: Tool changer code - persist.UserData
> To: DynoMotion@yahoogroups.com
> Date: Wednesday, June 22, 2011, 10:17 AM
>
>
>  
>
>
>
>
>
> Does the persist.UserData store data for the next time the c program is run? Like for knowing which tool is in the chuck the next time the toolchange calls? There is a small toolchanger.c example, but a bit more info would be helpful.
>
> Todd
>
> --- In DynoMotion@yahoogroups.com, "morgtod" <todmorg@> wrote:
> >
> > Are there any tool changer examples? I have a 12 position rotary and a 10 position pick and place for 2 different spindles on the same machine ( 1-7000 rpm and 1-40000 rpm spindle ). I would like to be able to pick which spindle is going to be used by the tool #, like 49 and below turn on the low speed, and 50 and above turn on the high speed with an offset in the x because the high speed is a couple inces to the left.
> >
> > Note- The spindles are at a fixed X distance from each other.
> >
> > Todd
> >
>

  @@attachment@@
Group: DynoMotion Message: 1337 From: Tom Kerekes Date: 6/22/2011
Subject: Re: Tool changer code - persist.UserData
You could add a test of a global persist variable to check for this.  The persist variables are guaranteed to be zero on power up.  So set one to a value when home completes then add a test for non-zero in the ToolChange program


--- On Wed, 6/22/11, morgtod <todmorg@...> wrote:

From: morgtod <todmorg@...>
Subject: [DynoMotion] Re: Tool changer code - persist.UserData
To: DynoMotion@yahoogroups.com
Date: Wednesday, June 22, 2011, 11:53 AM

 
one more important detail- do not allow a toolchange if the machine has not been homed!!!

--- In DynoMotion@yahoogroups.com, "morgtod" <todmorg@...> wrote:
>
> Here's the rough sequence
>
> Machine is already homed
>
> 1-move to machine cordinates z-4, then x0,y5
> 2-sw8 high //toolarm solenoid
> 3-wait for opto in 4 //toolarm in position sensor, toggle e-stop and printscreen warning if not
> 4-toggle sw4, wait 4 seconds //low speed drawbar, drop tool
> 5-check opto in 5 went low//drawbar sensor, make sure tool dropped, toggle e-stop and printscreen warning if not
> 6-g0z0 // move up to clear tool tray
> 7-turn tool tray to new tool // I have the tray setup as "A" for now, with the tools at 1" steps, ( g0a6 turns the tray to tool6 )
> 8-g0z-4 // drop down into pickup position
> 9-disable sw4 // grab the tool with low speed drawbar, the grabbing action lifts the tool off the tray far enough for the tray to swing away
> 10-check opto in 5 went high//make sure new tool has been grabbed, toggle e-stop and printscreen warning if not
> 11-sw8 low // toolarm retract
> 12-check opto in 3 // toolarm retracted sensor, toggle e-stop and printscreen warning if not
> 13- continue cutting
>
>
> This would get me going with one spindle, I would start on the 2nd after this is working.
>
> I'll post my toolchanger files in the files section of the group, one they are working.
>
>
> Thanks....
>
>
>
>
> --- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@> wrote:
> >
> > Hi Todd,
> >  
> > Yes the persist.UserData[100] variables are global and persist from one execution to the next and/or from one thread/program to the next.  So you could use that to pass info from the C program that does the Tool Change to the Spindle Program that turns on the Spindle so it knows which Spindle to turn on.  But actually the Tool Number is downloaded to the Tool Change program in a persist variable so it is probably already there.
> >  
> > Sorry we don't have more examples.  There are a lot of variation in Tool Changers.  The first step would probably be to try to do a tool change manually by toggling bits on the Digital IO Screen and/or Console Commands to see if you can find a sequence that works.  If you describe the sequence in detail I might be able to help.
> >  
> > Regards
> > TK
> >  
> >
> >
> > --- On Wed, 6/22/11, morgtod <todmorg@> wrote:
> >
> >
> > From: morgtod <todmorg@>
> > Subject: [DynoMotion] Re: Tool changer code - persist.UserData
> > To: DynoMotion@yahoogroups.com
> > Date: Wednesday, June 22, 2011, 10:17 AM
> >
> >
> >  
> >
> >
> >
> >
> >
> > Does the persist.UserData store data for the next time the c program is run? Like for knowing which tool is in the chuck the next time the toolchange calls? There is a small toolchanger.c example, but a bit more info would be helpful.
> >
> > Todd
> >
> > --- In DynoMotion@yahoogroups.com, "morgtod" <todmorg@> wrote:
> > >
> > > Are there any tool changer examples? I have a 12 position rotary and a 10 position pick and place for 2 different spindles on the same machine ( 1-7000 rpm and 1-40000 rpm spindle ). I would like to be able to pick which spindle is going to be used by the tool #, like 49 and below turn on the low speed, and 50 and above turn on the high speed with an offset in the x because the high speed is a couple inces to the left.
> > >
> > > Note- The spindles are at a fixed X distance from each other.
> > >
> > > Todd
> > >
> >
>

Group: DynoMotion Message: 1340 From: morgtod Date: 6/22/2011
Subject: Re: Tool changer code - persist.UserData
Thanks Tom,

That looks like the kind of information I was needing. I'll post back once I've got it swaping tools.

Todd

--- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@...> wrote:
>
> Hi Todd,
>  
> I've attached a rough program to hopefully get you started.
>  
> Just run, modify, and run it from the C Programs Screen until after it is working.  Then we can make it callable and use the passed Tool number from KMotionCNC.
>  
> I hope this helps.
>  
> TK
>
> --- On Wed, 6/22/11, morgtod <todmorg@...> wrote:
>
>
> From: morgtod <todmorg@...>
> Subject: [DynoMotion] Re: Tool changer code - persist.UserData
> To: DynoMotion@yahoogroups.com
> Date: Wednesday, June 22, 2011, 11:17 AM
>
>
>  
>
>
>
> Here's the rough sequence
>
> Machine is already homed
>
> 1-move to machine cordinates z-4, then x0,y5
> 2-sw8 high //toolarm solenoid
> 3-wait for opto in 4 //toolarm in position sensor, toggle e-stop and printscreen warning if not
> 4-toggle sw4, wait 4 seconds //low speed drawbar, drop tool
> 5-check opto in 5 went low//drawbar sensor, make sure tool dropped, toggle e-stop and printscreen warning if not
> 6-g0z0 // move up to clear tool tray
> 7-turn tool tray to new tool // I have the tray setup as "A" for now, with the tools at 1" steps, ( g0a6 turns the tray to tool6 )
> 8-g0z-4 // drop down into pickup position
> 9-disable sw4 // grab the tool with low speed drawbar, the grabbing action lifts the tool off the tray far enough for the tray to swing away
> 10-check opto in 5 went high//make sure new tool has been grabbed, toggle e-stop and printscreen warning if not
> 11-sw8 low // toolarm retract
> 12-check opto in 3 // toolarm retracted sensor, toggle e-stop and printscreen warning if not
> 13- continue cutting
>
> This would get me going with one spindle, I would start on the 2nd after this is working.
>
> I'll post my toolchanger files in the files section of the group, one they are working.
>
> Thanks....
>
> --- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@> wrote:
> >
> > Hi Todd,
> >  
> > Yes the persist.UserData[100] variables are global and persist from one execution to the next and/or from one thread/program to the next.  So you could use that to pass info from the C program that does the Tool Change to the Spindle Program that turns on the Spindle so it knows which Spindle to turn on.  But actually the Tool Number is downloaded to the Tool Change program in a persist variable so it is probably already there.
> >  
> > Sorry we don't have more examples.  There are a lot of variation in Tool Changers.  The first step would probably be to try to do a tool change manually by toggling bits on the Digital IO Screen and/or Console Commands to see if you can find a sequence that works.  If you describe the sequence in detail I might be able to help.
> >  
> > Regards
> > TK
> >  
> >
> >
> > --- On Wed, 6/22/11, morgtod <todmorg@> wrote:
> >
> >
> > From: morgtod <todmorg@>
> > Subject: [DynoMotion] Re: Tool changer code - persist.UserData
> > To: DynoMotion@yahoogroups.com
> > Date: Wednesday, June 22, 2011, 10:17 AM
> >
> >
> >  
> >
> >
> >
> >
> >
> > Does the persist.UserData store data for the next time the c program is run? Like for knowing which tool is in the chuck the next time the toolchange calls? There is a small toolchanger.c example, but a bit more info would be helpful.
> >
> > Todd
> >
> > --- In DynoMotion@yahoogroups.com, "morgtod" <todmorg@> wrote:
> > >
> > > Are there any tool changer examples? I have a 12 position rotary and a 10 position pick and place for 2 different spindles on the same machine ( 1-7000 rpm and 1-40000 rpm spindle ). I would like to be able to pick which spindle is going to be used by the tool #, like 49 and below turn on the low speed, and 50 and above turn on the high speed with an offset in the x because the high speed is a couple inces to the left.
> > >
> > > Note- The spindles are at a fixed X distance from each other.
> > >
> > > Todd
> > >
> >
>
Group: DynoMotion Message: 1341 From: morgtod Date: 6/22/2011
Subject: Re: Tool changer code - persist.UserData
Tom,
If I'm following you correctly, the persist.UserData will be lost on a Kflop reboot and set to 0. What I'm looking for is a way for the Kflop to remember which tool is in the spindle, even after being rebooted. Is this possible?

Todd

--- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@...> wrote:
>
> Hi Todd,
>  
> Yes the persist.UserData[100] variables are global and persist from one execution to the next and/or from one thread/program to the next.  So you could use that to pass info from the C program that does the Tool Change to the Spindle Program that turns on the Spindle so it knows which Spindle to turn on.  But actually the Tool Number is downloaded to the Tool Change program in a persist variable so it is probably already there.
>  
> Sorry we don't have more examples.  There are a lot of variation in Tool Changers.  The first step would probably be to try to do a tool change manually by toggling bits on the Digital IO Screen and/or Console Commands to see if you can find a sequence that works.  If you describe the sequence in detail I might be able to help.
>  
> Regards
> TK
>  
>
>
> --- On Wed, 6/22/11, morgtod <todmorg@...> wrote:
>
>
> From: morgtod <todmorg@...>
> Subject: [DynoMotion] Re: Tool changer code - persist.UserData
> To: DynoMotion@yahoogroups.com
> Date: Wednesday, June 22, 2011, 10:17 AM
>
>
>  
>
>
>
>
>
> Does the persist.UserData store data for the next time the c program is run? Like for knowing which tool is in the chuck the next time the toolchange calls? There is a small toolchanger.c example, but a bit more info would be helpful.
>
> Todd
>
> --- In DynoMotion@yahoogroups.com, "morgtod" <todmorg@> wrote:
> >
> > Are there any tool changer examples? I have a 12 position rotary and a 10 position pick and place for 2 different spindles on the same machine ( 1-7000 rpm and 1-40000 rpm spindle ). I would like to be able to pick which spindle is going to be used by the tool #, like 49 and below turn on the low speed, and 50 and above turn on the high speed with an offset in the x because the high speed is a couple inces to the left.
> >
> > Note- The spindles are at a fixed X distance from each other.
> >
> > Todd
> >
>
Group: DynoMotion Message: 1342 From: Tom Kerekes Date: 6/22/2011
Subject: Re: Tool changer code - persist.UserData
Hi Todd,
 
That is correct.  The User Data variables are cleared on boot up.
 
I can't think of an easy way to do that.  The best I can off is to know that you don't know :}
 
Actually we just added the capability for Flop to write to a disk file.  If we added a method of reading I suppose you could save the current tool to disk.  But whenever I've tried to do that kind of technique it becomes very complicated because of the many odd scenarios like powering down in the middle of a change, or switching versions, or if someone manually changed something, etc etc..
 
Another thought might be to add a method of having the operator set which tool is currently loaded.  Possibly an MID command to load tool 1006 might indicate that tool 6 is currently loaded.
 
TK

--- On Wed, 6/22/11, morgtod <todmorg@...> wrote:

From: morgtod <todmorg@...>
Subject: [DynoMotion] Re: Tool changer code - persist.UserData
To: DynoMotion@yahoogroups.com
Date: Wednesday, June 22, 2011, 4:48 PM

 
Tom,
If I'm following you correctly, the persist.UserData will be lost on a Kflop reboot and set to 0. What I'm looking for is a way for the Kflop to remember which tool is in the spindle, even after being rebooted. Is this possible?

Todd

--- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@...> wrote:
>
> Hi Todd,
>  
> Yes the persist.UserData[100] variables are global and persist from one execution to the next and/or from one thread/program to the next.  So you could use that to pass info from the C program that does the Tool Change to the Spindle Program that turns on the Spindle so it knows which Spindle to turn on.  But actually the Tool Number is downloaded to the Tool Change program in a persist variable so it is probably already there.
>  
> Sorry we don't have more examples.  There are a lot of variation in Tool Changers.  The first step would probably be to try to do a tool change manually by toggling bits on the Digital IO Screen and/or Console Commands to see if you can find a sequence that works.  If you describe the sequence in detail I might be able to help.
>  
> Regards
> TK
>  
>
>
> --- On Wed, 6/22/11, morgtod <todmorg@...> wrote:
>
>
> From: morgtod <todmorg@...>
> Subject: [DynoMotion] Re: Tool changer code - persist.UserData
> To: DynoMotion@yahoogroups.com
> Date: Wednesday, June 22, 2011, 10:17 AM
>
>
>  
>
>
>
>
>
> Does the persist.UserData store data for the next time the c program is run? Like for knowing which tool is in the chuck the next time the toolchange calls? There is a small toolchanger.c example, but a bit more info would be helpful.
>
> Todd
>
> --- In DynoMotion@yahoogroups.com, "morgtod" <todmorg@> wrote:
> >
> > Are there any tool changer examples? I have a 12 position rotary and a 10 position pick and place for 2 different spindles on the same machine ( 1-7000 rpm and 1-40000 rpm spindle ). I would like to be able to pick which spindle is going to be used by the tool #, like 49 and below turn on the low speed, and 50 and above turn on the high speed with an offset in the x because the high speed is a couple inces to the left.
> >
> > Note- The spindles are at a fixed X distance from each other.
> >
> > Todd
> >
>

Group: DynoMotion Message: 1346 From: morgtod Date: 6/23/2011
Subject: Re: Tool changer code - persist.UserData
I think I will do a park routine to unload all tools, move to an odd , but specific location and shut down.

Then in my init file I will count the steps to the home location and trigger a E-Stop if it does not match the park location, this will verify that the park routine was completed before shutdown. The tool tray zeros using the index every init, and it's a 1-1 drive, so index mark=tool 1.


Todd

--- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@...> wrote:
>
> Hi Todd,
>  
> That is correct.  The User Data variables are cleared on boot up.
>  
> I can't think of an easy way to do that.  The best I can off is to know that you don't know :}
>  
> Actually we just added the capability for Flop to write to a disk file.  If we added a method of reading I suppose you could save the current tool to disk.  But whenever I've tried to do that kind of technique it becomes very complicated because of the many odd scenarios like powering down in the middle of a change, or switching versions, or if someone manually changed something, etc etc..
>  
> Another thought might be to add a method of having the operator set which tool is currently loaded.  Possibly an MID command to load tool 1006 might indicate that tool 6 is currently loaded.
>  
> TK
>
> --- On Wed, 6/22/11, morgtod <todmorg@...> wrote:
>
>
> From: morgtod <todmorg@...>
> Subject: [DynoMotion] Re: Tool changer code - persist.UserData
> To: DynoMotion@yahoogroups.com
> Date: Wednesday, June 22, 2011, 4:48 PM
>
>
>  
>
>
>
> Tom,
> If I'm following you correctly, the persist.UserData will be lost on a Kflop reboot and set to 0. What I'm looking for is a way for the Kflop to remember which tool is in the spindle, even after being rebooted. Is this possible?
>
> Todd
>
> --- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@> wrote:
> >
> > Hi Todd,
> >  
> > Yes the persist.UserData[100] variables are global and persist from one execution to the next and/or from one thread/program to the next.  So you could use that to pass info from the C program that does the Tool Change to the Spindle Program that turns on the Spindle so it knows which Spindle to turn on.  But actually the Tool Number is downloaded to the Tool Change program in a persist variable so it is probably already there.
> >  
> > Sorry we don't have more examples.  There are a lot of variation in Tool Changers.  The first step would probably be to try to do a tool change manually by toggling bits on the Digital IO Screen and/or Console Commands to see if you can find a sequence that works.  If you describe the sequence in detail I might be able to help.
> >  
> > Regards
> > TK
> >  
> >
> >
> > --- On Wed, 6/22/11, morgtod <todmorg@> wrote:
> >
> >
> > From: morgtod <todmorg@>
> > Subject: [DynoMotion] Re: Tool changer code - persist.UserData
> > To: DynoMotion@yahoogroups.com
> > Date: Wednesday, June 22, 2011, 10:17 AM
> >
> >
> >  
> >
> >
> >
> >
> >
> > Does the persist.UserData store data for the next time the c program is run? Like for knowing which tool is in the chuck the next time the toolchange calls? There is a small toolchanger.c example, but a bit more info would be helpful.
> >
> > Todd
> >
> > --- In DynoMotion@yahoogroups.com, "morgtod" <todmorg@> wrote:
> > >
> > > Are there any tool changer examples? I have a 12 position rotary and a 10 position pick and place for 2 different spindles on the same machine ( 1-7000 rpm and 1-40000 rpm spindle ). I would like to be able to pick which spindle is going to be used by the tool #, like 49 and below turn on the low speed, and 50 and above turn on the high speed with an offset in the x because the high speed is a couple inces to the left.
> > >
> > > Note- The spindles are at a fixed X distance from each other.
> > >
> > > Todd
> > >
> >
>
Group: DynoMotion Message: 1348 From: Tom Kerekes Date: 6/23/2011
Subject: Re: Tool changer code - persist.UserData
Very clever.
TK

--- On Thu, 6/23/11, morgtod <todmorg@...> wrote:

From: morgtod <todmorg@...>
Subject: [DynoMotion] Re: Tool changer code - persist.UserData
To: DynoMotion@yahoogroups.com
Date: Thursday, June 23, 2011, 7:10 AM

 
I think I will do a park routine to unload all tools, move to an odd , but specific location and shut down.

Then in my init file I will count the steps to the home location and trigger a E-Stop if it does not match the park location, this will verify that the park routine was completed before shutdown. The tool tray zeros using the index every init, and it's a 1-1 drive, so index mark=tool 1.

Todd

--- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@...> wrote:
>
> Hi Todd,
>  
> That is correct.  The User Data variables are cleared on boot up.
>  
> I can't think of an easy way to do that.  The best I can off is to know that you don't know :}
>  
> Actually we just added the capability for Flop to write to a disk file.  If we added a method of reading I suppose you could save the current tool to disk.  But whenever I've tried to do that kind of technique it becomes very complicated because of the many odd scenarios like powering down in the middle of a change, or switching versions, or if someone manually changed something, etc etc..
>  
> Another thought might be to add a method of having the operator set which tool is currently loaded.  Possibly an MID command to load tool 1006 might indicate that tool 6 is currently loaded.
>  
> TK
>
> --- On Wed, 6/22/11, morgtod <todmorg@...> wrote:
>
>
> From: morgtod <todmorg@...>
> Subject: [DynoMotion] Re: Tool changer code - persist.UserData
> To: DynoMotion@yahoogroups.com
> Date: Wednesday, June 22, 2011, 4:48 PM
>
>
>  
>
>
>
> Tom,
> If I'm following you correctly, the persist.UserData will be lost on a Kflop reboot and set to 0. What I'm looking for is a way for the Kflop to remember which tool is in the spindle, even after being rebooted. Is this possible?
>
> Todd
>
> --- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@> wrote:
> >
> > Hi Todd,
> >  
> > Yes the persist.UserData[100] variables are global and persist from one execution to the next and/or from one thread/program to the next.  So you could use that to pass info from the C program that does the Tool Change to the Spindle Program that turns on the Spindle so it knows which Spindle to turn on.  But actually the Tool Number is downloaded to the Tool Change program in a persist variable so it is probably already there.
> >  
> > Sorry we don't have more examples.  There are a lot of variation in Tool Changers.  The first step would probably be to try to do a tool change manually by toggling bits on the Digital IO Screen and/or Console Commands to see if you can find a sequence that works.  If you describe the sequence in detail I might be able to help.
> >  
> > Regards
> > TK
> >  
> >
> >
> > --- On Wed, 6/22/11, morgtod <todmorg@> wrote:
> >
> >
> > From: morgtod <todmorg@>
> > Subject: [DynoMotion] Re: Tool changer code - persist.UserData
> > To: DynoMotion@yahoogroups.com
> > Date: Wednesday, June 22, 2011, 10:17 AM
> >
> >
> >  
> >
> >
> >
> >
> >
> > Does the persist.UserData store data for the next time the c program is run? Like for knowing which tool is in the chuck the next time the toolchange calls? There is a small toolchanger.c example, but a bit more info would be helpful.
> >
> > Todd
> >
> > --- In DynoMotion@yahoogroups.com, "morgtod" <todmorg@> wrote:
> > >
> > > Are there any tool changer examples? I have a 12 position rotary and a 10 position pick and place for 2 different spindles on the same machine ( 1-7000 rpm and 1-40000 rpm spindle ). I would like to be able to pick which spindle is going to be used by the tool #, like 49 and below turn on the low speed, and 50 and above turn on the high speed with an offset in the x because the high speed is a couple inces to the left.
> > >
> > > Note- The spindles are at a fixed X distance from each other.
> > >
> > > Todd
> > >
> >
>

Group: DynoMotion Message: 1349 From: Lee Studley Date: 6/23/2011
Subject: Re: Tool changer code - persist.UserData
That is a cool idea. I was wondering about and alternative: a simple save off( at end of session or power down ) to an spi EEProm attached to I/O....
Just enough info to address a simple lookup table, or more if needed.
Their endurance cycle/life time are very good nowadays.
-Lee Studley

On 6/23/2011 9:04 AM, Tom Kerekes wrote:
 

Very clever.
TK

--- On Thu, 6/23/11, morgtod <todmorg@...> wrote:

From: morgtod <todmorg@...>
Subject: [DynoMotion] Re: Tool changer code - persist.UserData
To: DynoMotion@yahoogroups.com
Date: Thursday, June 23, 2011, 7:10 AM

 
I think I will do a park routine to unload all tools, move to an odd , but specific location and shut down.

Then in my init file I will count the steps to the home location and trigger a E-Stop if it does not match the park location, this will verify that the park routine was completed before shutdown. The tool tray zeros using the index every init, and it's a 1-1 drive, so index mark=tool 1.

Todd

--- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@...> wrote:
>
> Hi Todd,
>  
> That is correct.  The User Data variables are cleared on boot up.
>  
> I can't think of an easy way to do that.  The best I can off is to know that you don't know :}
>  
> Actually we just added the capability for Flop to write to a disk file.  If we added a method of reading I suppose you could save the current tool to disk.  But whenever I've tried to do that kind of technique it becomes very complicated because of the many odd scenarios like powering down in the middle of a change, or switching versions, or if someone manually changed something, etc etc..
>  
> Another thought might be to add a method of having the operator set which tool is currently loaded.  Possibly an MID command to load tool 1006 might indicate that tool 6 is currently loaded.
>  
> TK
>
> --- On Wed, 6/22/11, morgtod <todmorg@...> wrote:
>
>
> From: morgtod <todmorg@...>
> Subject: [DynoMotion] Re: Tool changer code - persist.UserData
> To: DynoMotion@yahoogroups.com
> Date: Wednesday, June 22, 2011, 4:48 PM
>
>
>  
>
>
>
> Tom,
> If I'm following you correctly, the persist.UserData will be lost on a Kflop reboot and set to 0. What I'm looking for is a way for the Kflop to remember which tool is in the spindle, even after being rebooted. Is this possible?
>
> Todd
>
> --- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@> wrote:
> >
> > Hi Todd,
> >  
> > Yes the persist.UserData[100] variables are global and persist from one execution to the next and/or from one thread/program to the next.  So you could use that to pass info from the C program that does the Tool Change to the Spindle Program that turns on the Spindle so it knows which Spindle to turn on.  But actually the Tool Number is downloaded to the Tool Change program in a persist variable so it is probably already there.
> >  
> > Sorry we don't have more examples.  There are a lot of variation in Tool Changers.  The first step would probably be to try to do a tool change manually by toggling bits on the Digital IO Screen and/or Console Commands to see if you can find a sequence that works.  If you describe the sequence in detail I might be able to help.
> >  
> > Regards
> > TK
> >  
> >
> >
> > --- On Wed, 6/22/11, morgtod <todmorg@> wrote:
> >
> >
> > From: morgtod <todmorg@>
> > Subject: [DynoMotion] Re: Tool changer code - persist.UserData
> > To: DynoMotion@yahoogroups.com
> > Date: Wednesday, June 22, 2011, 10:17 AM
> >
> >
> >  
> >
> >
> >
> >
> >
> > Does the persist.UserData store data for the next time the c program is run? Like for knowing which tool is in the chuck the next time the toolchange calls? There is a small toolchanger.c example, but a bit more info would be helpful.
> >
> > Todd
> >
> > --- In DynoMotion@yahoogroups.com, "morgtod" <todmorg@> wrote:
> > >
> > > Are there any tool changer examples? I have a 12 position rotary and a 10 position pick and place for 2 different spindles on the same machine ( 1-7000 rpm and 1-40000 rpm spindle ). I would like to be able to pick which spindle is going to be used by the tool #, like 49 and below turn on the low speed, and 50 and above turn on the high speed with an offset in the x because the high speed is a couple inces to the left.
> > >
> > > Note- The spindles are at a fixed X distance from each other.
> > >
> > > Todd
> > >
> >
>